package com.xhwl.logistics.strategy.impl;

import com.xhwl.logistics.bo.cent.VehicleIntegratedConfigBO;
import com.xhwl.logistics.bo.manipulate.CreateVehicleBlacklistHttpBO;
import com.xhwl.logistics.bo.manipulate.DeleteVehicleBlacklistHttpBO;
import com.xhwl.logistics.converter.mapstruct.VehicleBlacklistConverter;
import com.xhwl.logistics.dto.http.manipulation.AddCarBlackKeTopDTO;
import com.xhwl.logistics.dto.http.manipulation.DeleteCarBlackKeTopDTO;
import com.xhwl.logistics.service.impl.http.KeTopHttpServiceImpl;
import com.xhwl.logistics.strategy.IVehicleParkingLotBlacklistHandler;
import org.springframework.beans.factory.annotation.Autowired;

//@Service
public class VehicleParkingLotKeTopBlacklistHandlerImpl implements IVehicleParkingLotBlacklistHandler {

    @Autowired
    private KeTopHttpServiceImpl keTopHttpService;

    @Autowired
    private VehicleBlacklistConverter vehicleBlacklistConverter;

    @Override
    public void addCarBlack(VehicleIntegratedConfigBO vehicleIntegratedConfigBO, CreateVehicleBlacklistHttpBO createVehicleBlacklistHttpBO) {
        AddCarBlackKeTopDTO addCarBlackKeTopDTO = vehicleBlacklistConverter.createVehicleBlacklistHttpBO2AddCarBlackKeTopDTO(createVehicleBlacklistHttpBO);
        keTopHttpService.addCarBlack(vehicleIntegratedConfigBO, addCarBlackKeTopDTO);
    }

    @Override
    public void deleteCarBlack(VehicleIntegratedConfigBO vehicleIntegratedConfigBO, DeleteVehicleBlacklistHttpBO deleteVehicleBlacklistHttpBO) {
        DeleteCarBlackKeTopDTO deleteCarBlackKeTopDTO = vehicleBlacklistConverter.deleteVehicleBlacklistHttpBO2DeleteCarBlackKeTopDTO(deleteVehicleBlacklistHttpBO);
        keTopHttpService.deleteCarBlack(vehicleIntegratedConfigBO, deleteCarBlackKeTopDTO);
    }

}
